<?php

class CreateSessions extends Ruckusing_BaseMigration {

	public function up() {
    $sql = <<<SQL
      CREATE TABLE IF NOT EXISTS  `sessions` (
        session_id varchar(40) DEFAULT '0' NOT NULL,
        ip_address varchar(16) DEFAULT '0' NOT NULL,
        user_agent varchar(200) NOT NULL,
        last_activity int(10) unsigned DEFAULT 0 NOT NULL,
        user_data text,
        PRIMARY KEY (session_id)
      );
SQL;
    $this->execute($sql);
	}//up()

	public function down() {
    $this->drop_table('sessions');
	}//down()
}
?>
